/*
 * @Author: yangni 920556271@qq.com
 * @Date: 2023-11-30 16:40:49
 * @LastEditors: yangni 920556271@qq.com
 * @LastEditTime: 2023-12-05 22:36:32
 * @FilePath: /yt-devops/lib/pages/devices/device_list/components/filter_dialog.dart
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import 'package:bruno/bruno.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';

import 'package:yt_devops/resources/str_res_keys.dart';
import 'package:yt_devops/styles/styles.dart';

class FilterDialogWidget {
  static Widget addTag(Function toAddSite) {
    return InkWell(
      onTap: () => toAddSite(),
      child: Container(
        width: 104.w,
        height: 34.h,
        margin: EdgeInsets.fromLTRB(0, 6, 0, 6),
        decoration: BoxDecoration(
            color: BrnDefaultConfigUtils.defaultTagConfig.tagBackgroundColor,
            borderRadius: BorderRadius.circular(4.w)),
        child: Row(
          mainAxisAlignment: MainAxisAlignment.center,
          children: [
            Icon(
              Icons.add_circle_outline,
              size: 14.w,
              color: Colour.primaryColor,
            ),
            SizedBox(
              width: 3.w,
            ),
            Text(
              ResKey.add.tr,
              style: TextStyles.pf12,
            )
          ],
        ),
      ),
    );
  }

  static Widget pickTitle(String title) {
    return Padding(
      padding: EdgeInsets.only(top: 16.h, bottom: 6.h),
      child: Text(
        title,
        style: TextStyles.f14.boldStyle,
      ),
    );
  }
}
